package com.campus.academic.job.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 新闻表
 * </p>
 *
 * @author mwb
 * @since 2024-11-16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("news")
@ApiModel(value="News对象", description="新闻表")
public class News implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "标题")
    @TableField("title")
    private String title;

    @ApiModelProperty(value = "内容")
    @TableField("content")
    private String content;

    @ApiModelProperty(value = "新闻分类")
    @TableField("category")
    private String category;

    @ApiModelProperty(value = "发布状态（0待审核，1通过，2退回）")
    @TableField("status")
    private Integer status;

    @ApiModelProperty(value = "发布时间")
    @TableField("publish_date")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime publishDate;

    @ApiModelProperty(value = "修改时间")
    @TableField("change_date")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime changeDate;

    @ApiModelProperty(value = "发布人id")
    @TableField("publish_id")
    private Integer publishId;

    @ApiModelProperty(value = "是否删除（0否，1是）")
    @TableField("is_deleted")
    private Boolean isDeleted;
}
